3.30 \(\int \frac{\sin (e+f x)}{a+b \sec ^2(e+f x)} \, dx\)

Optimal. Leaf size=47 \[ \frac{\sqrt{b} \tan ^{-1}\left (\frac{\sqrt{a} \cos (e+f x)}{\sqrt{b}}\right )}{a^{3/2} f}-\frac{\cos (e+f x)}{a f} \]

[Out]

(Sqrt[b]*ArcTan[(Sqrt[a]*Cos[e + f*x])/Sqrt[b]])/(a^(3/2)*f) - Cos[e + f*x]/(a*f)

________________________________________________________________________________________

Rubi [A]  time = 0.0408325, antiderivative size = 47, normalized size of antiderivative = 1., number of steps used = 3, number of rules used = 3, integrand size = 21, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.143, Rules used = {4133, 321, 205} \[ \frac{\sqrt{b} \tan ^{-1}\left (\frac{\sqrt{a} \cos (e+f x)}{\sqrt{b}}\right )}{a^{3/2} f}-\frac{\cos (e+f x)}{a f} \]

Antiderivative was successfully verified.

[In]

Int[Sin[e + f*x]/(a + b*Sec[e + f*x]^2),x]

[Out]

(Sqrt[b]*ArcTan[(Sqrt[a]*Cos[e + f*x])/Sqrt[b]])/(a^(3/2)*f) - Cos[e + f*x]/(a*f)

Rule 4133

Int[((a_) + (b_.)*sec[(e_.) + (f_.)*(x_)]^(n_))^(p_.)*sin[(e_.) + (f_.)*(x_)]^(m_.), x_Symbol] :> With[{ff = F
reeFactors[Cos[e + f*x], x]}, -Dist[ff/f, Subst[Int[((1 - ff^2*x^2)^((m - 1)/2)*(b + a*(ff*x)^n)^p)/(ff*x)^(n*
p), x], x, Cos[e + f*x]/ff], x]] /; FreeQ[{a, b, e, f}, x] && IntegerQ[(m - 1)/2] && IntegerQ[n] && IntegerQ[p
]

Rule 321

Int[((c_.)*(x_))^(m_)*((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> Simp[(c^(n - 1)*(c*x)^(m - n + 1)*(a + b*x^n
)^(p + 1))/(b*(m + n*p + 1)), x] - Dist[(a*c^n*(m - n + 1))/(b*(m + n*p + 1)), Int[(c*x)^(m - n)*(a + b*x^n)^p
, x], x] /; FreeQ[{a, b, c, p}, x] && IGtQ[n, 0] && GtQ[m, n - 1] && NeQ[m + n*p + 1, 0] && IntBinomialQ[a, b,
 c, n, m, p, x]

Rule 205

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(Rt[a/b, 2]*ArcTan[x/Rt[a/b, 2]])/a, x] /; FreeQ[{a, b}, x]
&& PosQ[a/b]

Rubi steps

\begin{align*} \int \frac{\sin (e+f x)}{a+b \sec ^2(e+f x)} \, dx &=-\frac{\operatorname{Subst}\left (\int \frac{x^2}{b+a x^2} \, dx,x,\cos (e+f x)\right )}{f}\\ &=-\frac{\cos (e+f x)}{a f}+\frac{b \operatorname{Subst}\left (\int \frac{1}{b+a x^2} \, dx,x,\cos (e+f x)\right )}{a f}\\ &=\frac{\sqrt{b} \tan ^{-1}\left (\frac{\sqrt{a} \cos (e+f x)}{\sqrt{b}}\right )}{a^{3/2} f}-\frac{\cos (e+f x)}{a f}\\ \end{align*}

Mathematica [C]  time = 0.957014, size = 329, normalized size = 7. \[ \frac{(a \cos (2 (e+f x))+a+2 b) \left (-4 \sqrt{a} \sqrt{b} \cos (e+f x)-a \tan ^{-1}\left (\frac{\sqrt{a}-\sqrt{a+b} \tan \left (\frac{1}{2} (e+f x)\right )}{\sqrt{b}}\right )-a \tan ^{-1}\left (\frac{\sqrt{a+b} \tan \left (\frac{1}{2} (e+f x)\right )+\sqrt{a}}{\sqrt{b}}\right )+(a+4 b) \tan ^{-1}\left (\frac{\sin (e) \tan \left (\frac{f x}{2}\right ) \left (-\sqrt{a}-i \sqrt{a+b} \sqrt{(\cos (e)-i \sin (e))^2}\right )+\cos (e) \left (\sqrt{a}-\sqrt{a+b} \sqrt{(\cos (e)-i \sin (e))^2} \tan \left (\frac{f x}{2}\right )\right )}{\sqrt{b}}\right )+(a+4 b) \tan ^{-1}\left (\frac{\sin (e) \tan \left (\frac{f x}{2}\right ) \left (-\sqrt{a}+i \sqrt{a+b} \sqrt{(\cos (e)-i \sin (e))^2}\right )+\cos (e) \left (\sqrt{a}+\sqrt{a+b} \sqrt{(\cos (e)-i \sin (e))^2} \tan \left (\frac{f x}{2}\right )\right )}{\sqrt{b}}\right )\right )}{8 a^{3/2} \sqrt{b} f \left (a \cos ^2(e+f x)+b\right )} \]

Antiderivative was successfully verified.

[In]

Integrate[Sin[e + f*x]/(a + b*Sec[e + f*x]^2),x]

[Out]

(((a + 4*b)*ArcTan[((-Sqrt[a] - I*Sqrt[a + b]*Sqrt[(Cos[e] - I*Sin[e])^2])*Sin[e]*Tan[(f*x)/2] + Cos[e]*(Sqrt[
a] - Sqrt[a + b]*Sqrt[(Cos[e] - I*Sin[e])^2]*Tan[(f*x)/2]))/Sqrt[b]] + (a + 4*b)*ArcTan[((-Sqrt[a] + I*Sqrt[a
+ b]*Sqrt[(Cos[e] - I*Sin[e])^2])*Sin[e]*Tan[(f*x)/2] + Cos[e]*(Sqrt[a] + Sqrt[a + b]*Sqrt[(Cos[e] - I*Sin[e])
^2]*Tan[(f*x)/2]))/Sqrt[b]] - a*ArcTan[(Sqrt[a] - Sqrt[a + b]*Tan[(e + f*x)/2])/Sqrt[b]] - a*ArcTan[(Sqrt[a] +
 Sqrt[a + b]*Tan[(e + f*x)/2])/Sqrt[b]] - 4*Sqrt[a]*Sqrt[b]*Cos[e + f*x])*(a + 2*b + a*Cos[2*(e + f*x)]))/(8*a
^(3/2)*Sqrt[b]*f*(b + a*Cos[e + f*x]^2))

________________________________________________________________________________________

Maple [A]  time = 0.033, size = 46, normalized size = 1. \begin{align*} -{\frac{b}{fa}\arctan \left ({b\sec \left ( fx+e \right ){\frac{1}{\sqrt{ab}}}} \right ){\frac{1}{\sqrt{ab}}}}-{\frac{1}{fa\sec \left ( fx+e \right ) }} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(sin(f*x+e)/(a+b*sec(f*x+e)^2),x)

[Out]

-1/f*b/a/(a*b)^(1/2)*arctan(sec(f*x+e)*b/(a*b)^(1/2))-1/f/a/sec(f*x+e)

________________________________________________________________________________________

Maxima [F(-2)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Exception raised: ValueError} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(f*x+e)/(a+b*sec(f*x+e)^2),x, algorithm="maxima")

[Out]

Exception raised: ValueError

________________________________________________________________________________________

Fricas [A]  time = 0.534208, size = 265, normalized size = 5.64 \begin{align*} \left [\frac{\sqrt{-\frac{b}{a}} \log \left (-\frac{a \cos \left (f x + e\right )^{2} + 2 \, a \sqrt{-\frac{b}{a}} \cos \left (f x + e\right ) - b}{a \cos \left (f x + e\right )^{2} + b}\right ) - 2 \, \cos \left (f x + e\right )}{2 \, a f}, \frac{\sqrt{\frac{b}{a}} \arctan \left (\frac{a \sqrt{\frac{b}{a}} \cos \left (f x + e\right )}{b}\right ) - \cos \left (f x + e\right )}{a f}\right ] \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(f*x+e)/(a+b*sec(f*x+e)^2),x, algorithm="fricas")

[Out]

[1/2*(sqrt(-b/a)*log(-(a*cos(f*x + e)^2 + 2*a*sqrt(-b/a)*cos(f*x + e) - b)/(a*cos(f*x + e)^2 + b)) - 2*cos(f*x
 + e))/(a*f), (sqrt(b/a)*arctan(a*sqrt(b/a)*cos(f*x + e)/b) - cos(f*x + e))/(a*f)]

________________________________________________________________________________________

Sympy [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{\sin{\left (e + f x \right )}}{a + b \sec ^{2}{\left (e + f x \right )}}\, dx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(f*x+e)/(a+b*sec(f*x+e)**2),x)

[Out]

Integral(sin(e + f*x)/(a + b*sec(e + f*x)**2), x)

________________________________________________________________________________________

Giac [A]  time = 1.21357, size = 59, normalized size = 1.26 \begin{align*} \frac{b \arctan \left (\frac{a \cos \left (f x + e\right )}{\sqrt{a b}}\right )}{\sqrt{a b} a f} - \frac{\cos \left (f x + e\right )}{a f} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(f*x+e)/(a+b*sec(f*x+e)^2),x, algorithm="giac")

[Out]

b*arctan(a*cos(f*x + e)/sqrt(a*b))/(sqrt(a*b)*a*f) - cos(f*x + e)/(a*f)